import Axios from '@/utils/request';

/**
 * 查询产品差异数据
 */
export function productCheckDifference(data): Promise<any> {
    return Axios.post('/ledger/product/check/difference', data);
}

/**
 * 查询产品校验数据
 */
export function productCheckList(data): Promise<any> {
    return Axios.post('/ledger/product/check/list', data);
}

/**
 * 获取产品台账明细数据
 */
export function productDetail(data): Promise<any> {
    return Axios.post('/ledger/product/detail', data);
}

/**
 * 查询产品台账数据
 */
export function productInfoList(data): Promise<any> {
    return Axios.post('/ledger/product/info/list', data);
}
/**
 * 修改产品台账数据
 */
export function productUpdate(data): Promise<any> {
    return Axios.post('/ledger/product/update', data);
}

/**
 * 校验通过
 */
export function differenceUpdate(data): Promise<any> {
    return Axios.post('/ledger/difference/update', data);
}

/**
 * 校验拒绝
 */
export function differenceCheckRefuse(data): Promise<any> {
    return Axios.post('/ledger/difference/checkRefuse ', data);
}

/**
 * 产品台账日志查询
 */
export function productCodeLog(data): Promise<any> {
    return Axios.post('/ledger/productCode/log', data);
}

/**
 * 根据字典代码查询字典信息
 */
export function strategryList(code: string): Promise<any> {
    return Axios.get('/ledger/dict/list/code/' + code);
}

/**
 * 同日反向列表
 */
export function sameDayReverseList(params: any): Promise<any> {
    return Axios.post('/ledger/productReverse/info/list', params);
}
/**
 * 同日反向的设置
 */
export function sameDayReverseSetting(params: any): Promise<any> {
    return Axios.post('/ledger/productReverse/update', params);
}

/**
 * 查看同日反向的设置修改记录
 */
export function getsameDayReverseRecords(code: string): Promise<any> {
    return Axios.post('/ledger/productReverse/log', { fdProductCode: code });
}
